﻿using System;
using System.Windows.Forms;
using NanoERP.Model;
using NanoERP.Common;

namespace NanoERP
{
    public partial class FrmStockLimit : Form
    {
        readonly Goodsinfo _goods;
        public FrmStockLimit()
        {
            InitializeComponent();
        }

        public FrmStockLimit(Goodsinfo goods)
        {
            InitializeComponent();

            _goods = goods;
        }

        private void button1_Click(object sender, EventArgs e)
        {
            _goods.LimitHnum = Normal.ToInt(nudHLimit.Value);
            _goods.LimitLnum = Normal.ToInt(nudLLimit.Value);

            this.Tag = _goods;
            this.DialogResult = DialogResult.OK;
        }
    }
}
